<template>
  <div>
    <div class="nav">
      <van-icon name="arrow-left" @click="fh"/>
      <P class="nav-t">消息中心</P>
    </div>
    <van-pull-refresh v-model="isLoading" success-text="刷新成功" @refresh="onRefresh">
      
      <div class="center">
        <ul class="box-t">
          <li>
            <span class="img tz"></span>
            <span class="info">
              <h3>系统通知</h3>
              <h4>哈皮巴斯得！祝你生日快乐！</h4>
            </span>
            <span class="p-l">1个月前</span>
          </li>
          <li>
            <span class="img dz"></span>
            <span class="info">
              <h3>赞</h3>
              <h4>一个赞都不给我！</h4>
            </span>
            <span class="p-l">1个月前</span>
          </li>
          <li>
            <span class="img pl"></span>
            <span class="info">
              <h3>评论</h3>
              <h4>暂时还没有收到评论</h4>
            </span>
            <span class="p-l">1个月前</span>
          </li>
        </ul>
        <div class="box-c" >全部私信</div>
        <ul class="box-b">
          <router-link to="/user/msgList" tag="li">
            <span class="img zw"></span>
            <span class="info">
              <h3>Zeng Wen</h3>
              <h4>暂时还没有收到评论</h4>
            </span>
            <div class="info-l">
              <span class="p">1个月前</span>
              <span class="p-b">1</span>
            </div>
          </router-link>
          <router-link to="/user/msgList" tag="li">
            <span class="img co"></span>
            <span class="info">
              <h3>Chikelu Obasea</h3>
              <h4>暂时还没有收到评论</h4>
            </span>
            <div class="info-l">
              <span class="p">1个月前</span>
              <span class="p-b">1</span>
            </div>
          </router-link>
          <router-link to="/user/msgList" tag="li">
            <span class="img km"></span>
            <span class="info">
              <h3>Kimmy McIlmorie</h3>
              <h4>暂时还没有收到评论</h4>
            </span>
            <div class="info-l">
              <span class="p">1个月前</span>
              <span class="p-b">1</span>
            </div>
          </router-link>
          <router-link to="/user/msgList" tag="li">
            <span class="img xj"></span>
            <span class="info">
              <h3>Xu Jianhong</h3>
              <h4>暂时还没有收到评论</h4>
            </span>
            <div class="info-l">
              <span class="p">1个月前</span>
              <span class="p-b">1</span>
            </div>
          </router-link>
          <router-link to="/user/msgList" tag="li">
            <span class="img kj"></span>
            <span class="info">
              <h3>Kung Jiyeon</h3>
              <h4>暂时还没有收到评论</h4>
            </span>
            <div class="info-l">
              <span class="p">1个月前</span>
              <span class="p-b">1</span>
            </div>
          </router-link>
        </ul>
      </div>
    </van-pull-refresh>
  </div>
</template>

<script>
export default {
  data() {
    return {
      isLoading: false
    };
  },
  methods: {
    onRefresh() {
      setTimeout(() => {
        this.isLoading = false;
      }, 1000);
    },
    fh() {
      this.$router.push({ path: "/user" });
    },
    goList() {
       this.$router.push({ name: 'msgList' });
       console.log("12312321");
    }
  },
  created() {}
};
</script>

<style lang="scss">
.nav {
  position: relative;
  margin-left: 42px;
  margin-top: 20px;
  .van-icon {
    opacity: 0.6;
    font-size: 32px;
    color: #fff;
    display: inline-block;
  }
  p {
    display: inline-block;
    font-size: 32px;
    color: #fff;
    position: absolute;
    left: 50%;
    transform: translatex(-80px);
    top: -5px;
  }
}
.center {
  width: 670px;
  margin: 56px 40px;
  .box-t {
    width: 100%;
    height: 376px;
    li {
      margin-top: 56px;
      height: 88px;
      width: 100%;
      .img {
        display: inline-block;
        height: 88px;
        width: 88px;
        border-radius: 50%;
        margin-right: 30px;
      }
      .info {
        color: #fff;
        height: 88px;
        vertical-align: top;
        width: 460px;
        display: inline-block;
      }
      h3 {
        font-size: 32px;
      }
      h4 {
        opacity: 0.6;
        font-size: 24px;
        display: inline-block;
      }
      .p-l {
        opacity: 0.6;
        color: #ffffff;
        vertical-align: middle;
        display: inline-block;
        height: 88px;
        width: 90px;
        margin-right: 0px;
      }
    }
    .tz {
      background: url(~@/assets/images/wzb/news/tz2x.png) no-repeat center;
      background-size: 50% 50%;
      background-color: #f9c34a;
    }
    .dz {
      background: url(~@/assets/images/wzb/news/dz2x.png) no-repeat center;
      background-size: 50% 50%;
      background-color: #ef8833;
    }
    .pl {
      background: url(~@/assets/images/wzb/news/pl2x.png) no-repeat center;
      background-size: 50% 50%;
      background-color: #6548a9;
    }
  }
  .box-c {
    color: #fff;
    font-size: 32px;
    margin-bottom: 30px;
    margin-top: 70px;
  }
  .box-b {
    width: 100%;
    li {
      margin-top: 34px;
      height: 86px;
      width: 100%;
      .img {
        display: inline-block;
        height: 86px;
        width: 88px;
        border-radius: 50%;
        margin-right: 30px;
      }
      .info {
        color: #fff;
        height: 86px;
        vertical-align: top;
        width: 460px;
        display: inline-block;
      }
      h3 {
        font-size: 28px;
        color: #f9c34a;
      }
      h4 {
        opacity: 0.6;
        font-size: 24px;
        display: inline-block;
      }
      .info-l {
        display: inline-block;
        vertical-align: top;
        text-align: right;
        height: 88px;
        width: 90px;
        color: #ffffff;
      }
      .p {
        opacity: 0.6;
      }
      .p-b {
        margin-top: 5px;
        text-align: center;
        display: inline-block;
        width: 28px;
        height: 28px;
        background-color: #f9c34a;
        font-size: 22px;
        border-radius: 50%;
      }
    }
    .zw {
      background: url(~@/assets/images/wzb/news/zw2x.png) no-repeat center;
      background-size: 100% 100%;
    }
    .co {
      background: url(~@/assets/images/wzb/news/co2x.png) no-repeat center;
      background-size: 100% 100%;
    }
    .km {
      background: url(~@/assets/images/wzb/news/km2x.png) no-repeat center;
      background-size: 100% 100%;
    }
    .xj {
      background: url(~@/assets/images/wzb/news/xj2x.png) no-repeat center;
      background-size: 100% 100%;
    }
    .kj {
      background: url(~@/assets/images/wzb/news/kj2x.png) no-repeat center;
      background-size: 100% 100%;
    }
  }
}
</style>